import {ArgumentMetadata, Injectable, PipeTransform} from '@nestjs/common';
import {TagEntity} from "../modules/tag/entity/tag.entity";

@Injectable()
export class TagPipe implements PipeTransform<any, TagEntity> {
    transform(value: any, metadata: ArgumentMetadata) {
        return TagEntity.of(value);
    }
}
